package com.ship.common.core.base;

import com.baomidou.mybatisplus.core.metadata.IPage;
import lombok.Data;

import java.util.List;

/**
 * @author 31463
 */
@Data
public class Page<T> {


    private long pageSize;
    private long pageNum;
    private long total;
    private List<T> list;

    public Page(IPage<T> iPage) {
        this.pageSize = iPage.getSize();
        this.pageNum = iPage.getCurrent();
        this.total = iPage.getTotal();
        this.list = iPage.getRecords();
    }

    public Page() {

    }
}
